package at.ltasat.test.level2;

import at.ltasat.classifier.ObjectFeatures;
import at.ltasat.classifier.ObjectFeaturesFactory;

public final class PointFeaturesFactory implements ObjectFeaturesFactory<Point> {

	@Override
	public int getNumberOfFeatures() {
		return 2;
	}

	@Override
	public ObjectFeatures create(Point point) {
		double[] values = new double[getNumberOfFeatures()];
		values[0] = point.x();
		values[1] = point.y();
		return new ObjectFeatures(values);
	}

}
